package com.zhangtai.modules.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.zhangtai.config.LongJsonDeserializer;
import com.zhangtai.config.LongJsonSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.util.Date;


@Data
public class SalaryGroupVo {

    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    @ApiModelProperty(value="薪资组分配id",required = true)
  //  @NotNull(message = "薪资组分配id不能为空")
    private Long id;

    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    @ApiModelProperty(value="员工id",required = true)
    private Long oid;


    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    @ApiModelProperty(value="工资组id",required = true)
    @NotNull(message = "工资组id不能为空")
    private Long salaryGroupId;

    @JsonDeserialize(using = LongJsonDeserializer.class)
    @JsonSerialize(using = LongJsonSerializer.class)
    @ApiModelProperty(value="发薪单位id",required = true)
    @NotNull(message = "发薪单位id不能为空")
    private Long payrollUnitId;

    /**
     * 变动类型   0专业晋级/1管理晋级/2试用转正/3入职定薪/4降级调薪/5薪资调整
     */
    @ApiModelProperty(value="发薪单位id")
    private Integer type=5;
    /**
     * 备注
     */
    @ApiModelProperty(value = "备注", required = false)
    private String remark;

    /**
     *  节税 0 否 1是
     */
    @ApiModelProperty(value = "节税 0 否 1是", required = false)
    private Integer isTax;

    @ApiModelProperty(value = "分配时间", required = false)
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date distributionTime;

}
